package org.acegisecurity.util;

import org.acegisecurity.Authentication;

/**
 * This interface must be implemented by the "compilers" to make dependency injection
 * possible.
 *
 * @author Jamie Craane
 * @author Ivo Woltring
 */
public interface ExpressionEvaluator {
    /**
     * @param expr           The expression to be evaluated
     * @param authentication the Authentication object containing the roles
     * @return boolean with the evaluation result
     * @throws IllegalExpressionException This exception is thrown if evaluation
     */
    public boolean match(String expr, Authentication authentication) throws IllegalExpressionException;
}